package cn.itcast.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
@RequestMapping("/hello")
public class BookController {
   @RequestMapping("/demo1")
    public String demo1(){
       System.out.println("进来了异常");
       int i= 10/0;
       return "book/success";
   }

    @RequestMapping("/demo2")
    public String demo2() {
        System.out.println("进来了Controller层");
        return "book/success";
    }

}
